#include <BSP/Switch.h>
#include <Core/GPIO.h>

extern "C" uint8_t Switch_IsPressed(uint8_t switch_id)
{
    if (switch_id < 16) {
        return (GPIO.IDR >> switch_id) & 1;
    }
    return 0;
}
